﻿@model Cadcam7Moddel.Model.Subject

@{
    ViewBag.Title = "Create";
}

@using (Html.BeginForm()) {
  <div class="subhead-collapse collapse">
    <div class="subhead">
        <div class="container-fluid">

            <div class="row-fluid">
                <div class="span12">
                    <div class="btn-toolbar" id="toolbar">
                        <div class="btn-wrapper" id="toolbar-apply">
                            <button type="submit" class="btn btn-small btn-success" value="Save" name="Submit">
                                <span class="icon-apply icon-white"></span>
                                Save
                            </button>
                        </div>
                        <div class="btn-wrapper" id="toolbar-save">
                            <button type="submit" class="btn btn-small" value="SaveClose" name="Submit">
                                <span class="icon-save"></span>
                                Save &amp; Close
                            </button>
                        </div>
                        <div class="btn-wrapper" id="toolbar-save-new">
                            <button type ="submit" class="btn btn-small" value="SaveNew" name="Submit" class="btn btn-small">
                                <span class="icon-save-new"></span>
                                Save &amp; New
                                </button>
                        </div>
                        <div class="btn-wrapper" id="toolbar-cancel">
                            <a href="@Url.Action("Index")" class="btn btn-small">
                                <span class="icon-cancel"></span>
                                Cancel
                            </a>

                        </div>
                        <div class="btn-group divider"></div>
                        <div class="btn-wrapper" id="toolbar-help">
                            <button rel="help" class="btn btn-small">
                                <span class="icon-question-sign"></span>
                                Help
                            </button>
                        </div>
                    </div>

                </div>
            </div>
        </div>
    </div>
</div>
    <div class="container-fluid container-main">
        <section id="content">
            <!-- Begin Content -->

            <div class="row-fluid">
                <div id="system-message-container">
                </div>
                <div class="row-fluid">

                    @Html.ValidationSummary()
                    <fieldset>

					    @Html.AntiForgeryToken()

        <div class="control-group">
		<div class="control-label">
            @Html.LabelFor(model => model.Name)
        </div>
        <div class="controls">
            @Html.EditorFor(model => model.Name)
            @Html.ValidationMessageFor(model => model.Name)
        </div>
		</div>

        

        <div class="control-group">
		<div class="control-label">
            @Html.LabelFor(model => model.NoiDung)
        </div>
        <div class="controls">
            @Html.TextAreaFor(model => model.NoiDung)
            @Html.ValidationMessageFor(model => model.NoiDung)
        </div>
		</div>

         </fieldset>	
    </div>

 </div>
            <!-- End Content -->
        </section>

    </div>
}
    <script type="text/javascript">

        var ck2 = CKEDITOR.instances['NoiDung'];
        if (ck2)//check if instance exist
        {
            CKEDITOR.remove(ck);
        }
        CKEDITOR.replace('NoiDung', {
            autoGrow_maxHeight: 300,
            removePlugins: 'resize',
            enterMode: CKEDITOR.ENTER_BR,
            filebrowserBrowseUrl: '@Url.Content("~/ckfinder/ckfinder.html")',
         filebrowserImageBrowseUrl: '@Url.Content("~/ckfinder/ckfinder.html?type=Images")',
         filebrowserUploadUrl: '@Url.Content("~/ckfinder/core/connector/aspx/connector.aspx?command=QuickUpload&type=Files")',
         filebrowserImageUploadUrl: '@Url.Content("~/ckfinder/core/connector/aspx/connector.aspx?command=QuickUpload&type=Images")',
         filebrowserWindowWidth: 800,
         filebrowserWindowHeight: 500,
         toolbar:
             [
                 { name: 'document', items: ['DocProps', 'Preview', 'Print', '-', 'Templates'] },
                 { name: 'clipboard', items: ['Cut', 'Copy', 'Paste', 'PasteText', 'PasteFromWord', '-', 'Undo', 'Redo'] },
                 { name: 'editing', items: ['Find', 'Replace', '-', 'SelectAll', '-', 'SpellChecker', 'Scayt'] },
                 { name: 'basicstyles', items: ['Bold', 'Italic', 'Underline', 'Strike', 'Subscript', 'Superscript', '-', 'RemoveFormat'] },
                 '/',
                 { name: 'styles', items: ['Styles', 'Format', 'Font', 'FontSize'] },
                 { name: 'colors', items: ['TextColor', 'BGColor'] },
                 { name: 'tools', items: ['Maximize', 'ShowBlocks'] },
                 '/',
                 { name: 'paragraph', items: ['NumberedList', 'BulletedList', '-', 'Outdent', 'Indent', '-', 'Blockquote', 'CreateDiv', '-', 'JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock', '-', 'BidiLtr', 'BidiRtl'] },
                 { name: 'links', items: ['Link', 'Unlink', 'Anchor'] },
                { name: 'insert', items: ['Image', 'Flash', 'Table', 'HorizontalRule', 'Smiley', 'SpecialChar', 'PageBreak', 'Iframe'] }
             ]
     });
</script>


@section Scripts {
@Scripts.Render("~/bundles/jquery")
    @Scripts.Render("~/bundles/jqueryval")
	@System.Web.Optimization.Scripts.Render("~/ckeditor/ckeditor.js")
@System.Web.Optimization.Scripts.Render("~/ckeditor/config.js")
@System.Web.Optimization.Scripts.Render("~/ckfinder/ckfinder.js")

}
